@extends('mbcore.baseadmin::layout.iframe')
@section('title', $subtitle)

@section('content')
    <style>
        .radio label{width:60px;}

        div{
            width:100%;
        }
        .radio label{
            width:60px;
        }
        .required_field{
            color:red;
        }
    </style>
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="row">
            <div class="col-sm-12">

                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>{{ $subtitle }}</h5>
                    </div>
                    <div class="ibox-content">
                        {{--<form  class="form-horizontal" action="{{route('admin.platform.manager.add')}}" method="post">--}}
                        {!! Form::open(['enctype'=>'multipart/form-data','class'=>'form-horizontal']) !!}

                        <div class="hr-line-dashed"></div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label required_field" style="text-align: center; width: 100%; font-size: 24px;">
                                预约须知
                            </label>

                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label required_field">
                            </label>
                            <div class="col-sm-10">
                                <label>
                                    <script id="editor" type="text/plain" style="width:1024px;height:500px;" name="content">{!! $content !!}</script>
                                </label>
                            </div>
                        </div>

                        @include('common.alert_error')

                        <div class="form-group">
                            <div class="col-sm-4 col-sm-offset-2">
                                <button class="btn btn-primary" type="submit">保存内容</button>
                            </div>
                        </div>
                        {{ csrf_field() }}
                        {!! Form::close() !!}
                    </div>
                </div>
            </div>
        </div>
    </div>
@stop

@section('myscript')
    <script src="{{ config('mbcore_baseadmin.baseadmin_assets_path')}}/js/plugins/validate/jquery.validate.min.js"></script>
    <script src="{{ config('mbcore_baseadmin.baseadmin_assets_path')}}/js/plugins/validate/messages_zh.min.js"></script>
    <script type="text/javascript" charset="utf-8" src="{{ config('mbcore_ueditor.ueditor_assets_path')}}/ueditor.config.js"></script>
    <script type="text/javascript" charset="utf-8" src="{{ config('mbcore_ueditor.ueditor_assets_path')}}/ueditor.all.min.js"> </script>
    <script>
        $(document).ready(function () {
            @if( count($errors)==1 && $errors->all()[0] == $params['success'])
            swal({
                title: "操作成功！",
                text: "2秒后自动关闭。",
                type: "success",
                timer: 2000,
                showConfirmButton: false
            },function(){
                location.reload(true);
            });
            @endif
        });
    </script>
    <script type="text/javascript">
        var ue = UE.getEditor('editor');
    </script>
@stop
